//$URL: http://dasding.googlecode.com/svn/tags/dasding-0.1/data/src/main/java/de/piratech/dasding/data/User.java $
//$Id: User.java 26 2012-10-07 23:22:51Z amuthmann@gmail.com $
/*
 * Copyright 2012 Piratech.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package de.piratech.dasding.data;

import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author deveth0
 */
@XmlRootElement
public class User extends AbstractDataObject {
  
  private String name;
  private String password;
  private String phone;
  private String mobile;
  private String mail;
  private List<ActionCategory> interests = new ArrayList<ActionCategory>();
  private boolean verified;
  private boolean admin;
  
  public String getName() {
    return name;
  }
  
  public void setName(String name) {
    this.name = name;
  }
  
  public String getPassword() {
    return password;
  }
  
  public void setPassword(String password) {
    this.password = password;
  }
  
  public String getPhone() {
    return phone;
  }
  
  public void setPhone(String phone) {
    this.phone = phone;
  }
  
  public String getMobile() {
    return mobile;
  }
  
  public void setMobile(String mobile) {
    this.mobile = mobile;
  }
  
  public String getMail() {
    return mail;
  }
  
  public void setMail(String mail) {
    this.mail = mail;
  }
  
  public boolean isVerified() {
    return verified;
  }
  
  public void setVerified(boolean verified) {
    this.verified = verified;
  }
  
  public boolean isAdmin() {
    return admin;
  }
  
  public void setAdmin(boolean admin) {
    this.admin = admin;
  }
  
  @XmlElementWrapper
  @XmlElement(name = "interest")
  public List<ActionCategory> getInterests() {
    return interests;
  }
  
  public void setInterests(List<ActionCategory> interests) {
    this.interests = interests;
  }
  
  public void addInterest(ActionCategory interest) {
    this.interests.add(interest);
  }
}
